package com.example.entry;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * 商品留言表
 */
@TableName(value ="product_message")
@Data
@AllArgsConstructor
@NoArgsConstructor
public class ProductMessage implements Serializable {
    private Integer id;

    private Integer orderId;

    private Integer userId;

    private String userName;

    private Integer productId;

    private String productName;

    private String messageContent;

    private Integer isDel;

//    @TableField(fill = FieldFill.INSERT)  // 新增数据时自动新增当前时间
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    private static final long serialVersionUID = 1L;
}